import Lexer as L
import Token as T
filePath = 'testDraw.txt'
lexer = L.Lexer(filePath)

print("token_type                         lexeme                         value      ptr")
print("--------------------------------------------------------------------------------")
while True:
    token = lexer.getToken()
    if token.tokenType != T.TokenType.NONTOKEN:
        token.disp()
    else:
        break
print("文本程序共", lexer.index, "行")